package com.spzx.controller;

import com.spzx.common.core.domain.R;
import com.spzx.service.ItemService;
import io.swagger.v3.oas.annotations.Operation;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/item")
public class ItemController {
    @Resource
    ItemService itemService;

    @GetMapping("/{skuId}")
    @Operation()
    public R itemById(@PathVariable("skuId") Long skuId) {
        itemService.itemById(skuId);
        return R.ok();
    }
}
